<?xml version='1.0' encoding='UTF-8' ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:p="http://primefaces.org/ui"
      xmlns:h="http://java.sun.com/jsf/html"
      xmlns:f="http://java.sun.com/jsf/core">
    <h:head>
        <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
        <title>
            <h:outputText value="Infosweb - WMS"/>
        </title>
        <link href="#{facesContext.externalContext.requestContextPath}/web-resources/css/default.css" rel="stylesheet" type="text/css"/>
    </h:head>
    <h:body>
        <p:layout fullPage="true">
            <!-- =========================================================== -->
            <p:layoutUnit position="north" size="64" closable="false" resizable="false" collapsible="false">
                <h:form id="defaultForm" prependId="true">
                    <table width="100%" border="0" cellpadding="0" cellspacing="0">
                        <tr>
                            <td width="33%" align="left">
                                <p:graphicImage value="/web-resources/imagenes/logo.png" width="233" height="53"/>
                            </td>
                            <td width="34%" align="center">
                                <p:ajaxStatus style="width: 48px; height: 48px;">
                                    <f:facet name="default">
                                        <h:outputText value="&nbsp;"/>
                                    </f:facet>
                                    <f:facet name="start">
                                        <p:graphicImage width="32" height="32" value="/web-resources/imagenes/108_1.gif"/>
                                    </f:facet>
                                    <f:facet name="complete">
                                        <h:outputText value="&nbsp;"/>
                                    </f:facet>                            
                                </p:ajaxStatus>
                            </td>
                            <td width="33%" align="right">
                                <p:splitButton id="iniciaSesionBT" value="Iniciar sesi&oacute;n" icon="ui-icon-locked" title="Cerrar sesi&oacute;n" oncomplete="inicioSesionPanel.show();" immediate="true">
                                    <p:menuitem icon="ui-icon-flag" value="Registro" immediate="true"/>
                                    <p:menuitem icon="ui-icon-key" value="Olvide mi contrase&ntilde;a" immediate="true"/>
                                </p:splitButton>                                
                            </td>
                        </tr>                        
                    </table>
                    <p:overlayPanel id="inicioSesionPanel" widgetVar="inicioSesionPanel" for="iniciaSesionBT" showEvent="none" showEffect="slide" hideEffect="slide">  
                        <p:panelGrid columns="2">
                            <f:facet name="header">  
                                <h:outputText value="Inicio de sesi&oacute;n"/>
                            </f:facet>
                            <h:outputText value="Usuario"/>
                            <p:inputText value="#{login.usuario}" required="true" label="Usuario"/>
                            <h:outputText value="Contrase&ntilde;a"/>
                            <p:password value="#{login.pass}" required="true" label="Contrase&ntilde;a"/>
                            <f:facet name="footer">
                                <p:commandButton id="is1cb" value="Iniciar sesi&oacute;n" action="#{login.iniciarSesion$action}" icon="ui-icon-locked" process="@(form)" update="@(form)"/>
                            </f:facet>
                            <p:defaultCommand target="is1cb" scope="inicioSesionPanel"/>
                        </p:panelGrid>
                    </p:overlayPanel>
                </h:form>
            </p:layoutUnit>
            <!-- =========================================================== -->
            <p:layoutUnit position="center" closable="false" resizable="false" collapsible="false">
                <h:form>
                    <p:carousel autoPlayInterval="5000" numVisible="1" circular="true" style="display: block; margin: auto;">
                        <p:graphicImage value="/web-resources/imagenes/infosgroup.jpg" width="900" height="460"/>
                        <p:graphicImage value="/web-resources/imagenes/infosgroup.jpg" width="900" height="460"/>
                        <p:graphicImage value="/web-resources/imagenes/infosgroup.jpg" width="900" height="460"/>
                    </p:carousel>
                </h:form>                
            </p:layoutUnit>
            <!-- =========================================================== -->
            <p:layoutUnit size="24" position="south" closable="false" resizable="false" collapsible="false" style="text-align: center;">
                <h:form>
                    <h:outputText value="&copy; 2012 - Infosgroup El Salvador"/>
                </h:form>
            </p:layoutUnit>
        </p:layout>        
        <!-- =============================================================== -->
        <h:form>
            <p:growl autoUpdate="true" showDetail="true" showSummary="false"/>
            <!--pe:ajaxErrorHandler button="Aceptar" title="Infosweb WMS"/-->
        </h:form>
    </h:body>
</html>